# !/usr/bin/env python3
# -*- coding: utf-8 -*-
# @Time : 2021/4/27 22:35
# @Author : daijun
# @Email : 1151737817@qq.com
# @File : 三创图片.py
# @Software: PyCharm
import re
import requests
result = requests.get("https://www.sanchuangedu.cn/")
ret = re.findall(r"(?<=img\ssrc=\").*(?=\"\salt)",result.text)
a = 0
for i in ret:
    picture = requests.get("https://www.sanchuangedu.cn"+i)
    with open(f"picture{a}.jpg","ab") as f:
        f.write(picture.content)
        a += 1